package cn.iocoder.yudao.module.pplan.enums;

import cn.hutool.core.util.ArrayUtil;
import lombok.AllArgsConstructor;
import lombok.Getter;

/**
 * project : hangshiServer
 * <p> 舱位等级 </p>
 *
 * @author yisl
 * @date 2025-07-17【星期四】
 **/
@Getter
@AllArgsConstructor
public enum PPlanMealServiceEnum {
    MEAL_SERVICE_1("1", "正餐"),
    MEAL_SERVICE_2("2", "点心"),
    MEAL_SERVICE_3("3", "早餐"),
    MEAL_SERVICE_4("4", "干点"),
    MEAL_SERVICE_5("5", "小吃"),
    MEAL_SERVICE_6("6", "机组早餐"),
    MEAL_SERVICE_7("7", "机组正餐");

    private final String code;
    private final String description;

    public static String getDesc(String code) {
        return ArrayUtil.firstMatch(userType -> userType.getCode().equals(code), PPlanMealServiceEnum.values()).getDescription();
    }
}
